Minor optimisation: Hibernate 2 metrics gc processes (backport #12149) (backport #12150) #12155
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Proposed Changes
It was observed that
rabbit_core_metrics_gcandrabbit_stream_metrics_gcprocesses can grow to several MBs of memory (probably because fetching the list of all queues). As they execute infrequently (every 2 minutes by default) it can save some memory to hibernate them in-between (similar to other similar processes).On an idle test server with 30K queues the
rabbit_core_metrics_gcprocess consumed ~50MB memory.This is an ad-hoc optimisation (low-hanging fruit) mostly to follow good practice of hibernating similar processes.
Types of Changes
What types of changes does your code introduce to this project?
Put an
xin the boxes that applyChecklist
Put an
xin the boxes that apply.You can also fill these out after creating the PR.
If you're unsure about any of them, don't hesitate to ask on the mailing list.
We're here to help!
This is simply a reminder of what we are going to look for before merging your code.
CONTRIBUTING.mddocumentFurther Comments
This is an automatic backport of pull request #12149 done by [Mergify](https://mergify.com).
This is an automatic backport of pull request #12150 done by [Mergify](https://mergify.com).